import 'package:codemode/models/sys_user_entity.dart';

sysUserEntityFromJson(SysUserEntity data, Map<String, dynamic> json) {
	if (json['userId'] != null) {
		data.userId = json['userId'].toString();
	}
	if (json['deptId'] != null) {
		data.deptId = json['deptId'].toString();
	}
	if (json['userName'] != null) {
		data.userName = json['userName'].toString();
	}
	if (json['nickName'] != null) {
		data.nickName = json['nickName'].toString();
	}
	if (json['deptName'] != null) {
		data.deptName = json['deptName'].toString();
	}
	if (json['userType'] != null) {
		data.userType = json['userType'].toString();
	}
	if (json['email'] != null) {
		data.email = json['email'].toString();
	}
	if (json['phonenumber'] != null) {
		data.phonenumber = json['phonenumber'].toString();
	}
	if (json['sex'] != null) {
		data.sex = json['sex'].toString();
	}
	if (json['avatar'] != null) {
		data.avatar = json['avatar'].toString();
	}
	if (json['password'] != null) {
		data.password = json['password'].toString();
	}
	if (json['status'] != null) {
		data.status = json['status'].toString();
	}
	if (json['delFlag'] != null) {
		data.delFlag = json['delFlag'].toString();
	}
	if (json['loginIp'] != null) {
		data.loginIp = json['loginIp'].toString();
	}
	if (json['loginDate'] != null) {
		data.loginDate = json['loginDate'].toString();
	}
	if (json['createBy'] != null) {
		data.createBy = json['createBy'].toString();
	}
	if (json['createTime'] != null) {
		data.createTime = json['createTime'].toString();
	}
	if (json['updateBy'] != null) {
		data.updateBy = json['updateBy'].toString();
	}
	if (json['updateTime'] != null) {
		data.updateTime = json['updateTime'].toString();
	}
	if (json['remark'] != null) {
		data.remark = json['remark'].toString();
	}
	return data;
}

Map<String, dynamic> sysUserEntityToJson(SysUserEntity entity) {
	final Map<String, dynamic> data = new Map<String, dynamic>();
	data['userId'] = entity.userId;
	data['deptId'] = entity.deptId;
	data['userName'] = entity.userName;
	data['nickName'] = entity.nickName;
	data['deptName'] = entity.deptName;
	data['userType'] = entity.userType;
	data['email'] = entity.email;
	data['phonenumber'] = entity.phonenumber;
	data['sex'] = entity.sex;
	data['avatar'] = entity.avatar;
	data['password'] = entity.password;
	data['status'] = entity.status;
	data['delFlag'] = entity.delFlag;
	data['loginIp'] = entity.loginIp;
	data['loginDate'] = entity.loginDate;
	data['createBy'] = entity.createBy;
	data['createTime'] = entity.createTime;
	data['updateBy'] = entity.updateBy;
	data['updateTime'] = entity.updateTime;
	data['remark'] = entity.remark;
	return data;
}